Integrand size = 31, antiderivative size = 96 \[ \int (a+a \cos (c+d x))^2 \left (A+C \cos ^2(c+d x)\right ) \sec (c+d x) \, dx=a^2 (2 A+C) x+\frac {a^2 A \text {arctanh}(\sin (c+d x))}{d}+\frac {a^2 (A+C) \sin (c+d x)}{d}+\frac {C (a+a \cos (c+d x))^2 \sin (c+d x)}{3 d}+\frac {C \left (a^2+a^2 \cos (c+d x)\right ) \sin (c+d x)}{3 d} \]
[Out]
Time = 0.33 (sec) , antiderivative size = 96, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 6, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.194, Rules used = {3125, 3055, 3047, 3102, 2814, 3855} \[ \int (a+a \cos (c+d x))^2 \left (A+C \cos ^2(c+d x)\right ) \sec (c+d x) \, dx=\frac {a^2 A \text {arctanh}(\sin (c+d x))}{d}+\frac {a^2 (A+C) \sin (c+d x)}{d}+a^2 x (2 A+C)+\frac {C \sin (c+d x) \left (a^2 \cos (c+d x)+a^2\right )}{3 d}+\frac {C \sin (c+d x) (a \cos (c+d x)+a)^2}{3 d} \]
[In]
[Out]
Rule 2814
Rule 3047
Rule 3055
Rule 3102
Rule 3125
Rule 3855
Rubi steps \begin{align*} \text {integral}& = \frac {C (a+a \cos (c+d x))^2 \sin (c+d x)}{3 d}+\frac {\int (a+a \cos (c+d x))^2 (3 a A+2 a C \cos (c+d x)) \sec (c+d x) \, dx}{3 a} \\ & = \frac {C (a+a \cos (c+d x))^2 \sin (c+d x)}{3 d}+\frac {C \left (a^2+a^2 \cos (c+d x)\right ) \sin (c+d x)}{3 d}+\frac {\int (a+a \cos (c+d x)) \left (6 a^2 A+6 a^2 (A+C) \cos (c+d x)\right ) \sec (c+d x) \, dx}{6 a} \\ & = \frac {C (a+a \cos (c+d x))^2 \sin (c+d x)}{3 d}+\frac {C \left (a^2+a^2 \cos (c+d x)\right ) \sin (c+d x)}{3 d}+\frac {\int \left (6 a^3 A+\left (6 a^3 A+6 a^3 (A+C)\right ) \cos (c+d x)+6 a^3 (A+C) \cos ^2(c+d x)\right ) \sec (c+d x) \, dx}{6 a} \\ & = \frac {a^2 (A+C) \sin (c+d x)}{d}+\frac {C (a+a \cos (c+d x))^2 \sin (c+d x)}{3 d}+\frac {C \left (a^2+a^2 \cos (c+d x)\right ) \sin (c+d x)}{3 d}+\frac {\int \left (6 a^3 A+6 a^3 (2 A+C) \cos (c+d x)\right ) \sec (c+d x) \, dx}{6 a} \\ & = a^2 (2 A+C) x+\frac {a^2 (A+C) \sin (c+d x)}{d}+\frac {C (a+a \cos (c+d x))^2 \sin (c+d x)}{3 d}+\frac {C \left (a^2+a^2 \cos (c+d x)\right ) \sin (c+d x)}{3 d}+\left (a^2 A\right ) \int \sec (c+d x) \, dx \\ & = a^2 (2 A+C) x+\frac {a^2 A \text {arctanh}(\sin (c+d x))}{d}+\frac {a^2 (A+C) \sin (c+d x)}{d}+\frac {C (a+a \cos (c+d x))^2 \sin (c+d x)}{3 d}+\frac {C \left (a^2+a^2 \cos (c+d x)\right ) \sin (c+d x)}{3 d} \\ \end{align*}
Time = 1.51 (sec) , antiderivative size = 109, normalized size of antiderivative = 1.14 \[ \int (a+a \cos (c+d x))^2 \left (A+C \cos ^2(c+d x)\right ) \sec (c+d x) \, dx=\frac {a^2 \left (24 A d x+12 C d x-12 A \log \left (\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )\right )+12 A \log \left (\cos \left (\frac {1}{2} (c+d x)\right )+\sin \left (\frac {1}{2} (c+d x)\right )\right )+3 (4 A+7 C) \sin (c+d x)+6 C \sin (2 (c+d x))+C \sin (3 (c+d x))\right )}{12 d} \]
[In]
[Out]
Time = 4.14 (sec) , antiderivative size = 86, normalized size of antiderivative = 0.90
method | result | size |
parallelrisch | \(-\frac {\left (A \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )-A \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )-\frac {\sin \left (2 d x +2 c \right ) C}{2}-\frac {\sin \left (3 d x +3 c \right ) C}{12}+\left (-A -\frac {7 C}{4}\right ) \sin \left (d x +c \right )-2 d x \left (A +\frac {C}{2}\right )\right ) a^{2}}{d}\) | \(86\) |
derivativedivides | \(\frac {A \,a^{2} \sin \left (d x +c \right )+\frac {a^{2} C \left (2+\cos ^{2}\left (d x +c \right )\right ) \sin \left (d x +c \right )}{3}+2 A \,a^{2} \left (d x +c \right )+2 a^{2} C \left (\frac {\cos \left (d x +c \right ) \sin \left (d x +c \right )}{2}+\frac {d x}{2}+\frac {c}{2}\right )+A \,a^{2} \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )+a^{2} C \sin \left (d x +c \right )}{d}\) | \(108\) |
default | \(\frac {A \,a^{2} \sin \left (d x +c \right )+\frac {a^{2} C \left (2+\cos ^{2}\left (d x +c \right )\right ) \sin \left (d x +c \right )}{3}+2 A \,a^{2} \left (d x +c \right )+2 a^{2} C \left (\frac {\cos \left (d x +c \right ) \sin \left (d x +c \right )}{2}+\frac {d x}{2}+\frac {c}{2}\right )+A \,a^{2} \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )+a^{2} C \sin \left (d x +c \right )}{d}\) | \(108\) |
parts | \(\frac {A \,a^{2} \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{d}+\frac {\left (A \,a^{2}+a^{2} C \right ) \sin \left (d x +c \right )}{d}+\frac {a^{2} C \left (2+\cos ^{2}\left (d x +c \right )\right ) \sin \left (d x +c \right )}{3 d}+\frac {2 A \,a^{2} \left (d x +c \right )}{d}+\frac {2 a^{2} C \left (\frac {\cos \left (d x +c \right ) \sin \left (d x +c \right )}{2}+\frac {d x}{2}+\frac {c}{2}\right )}{d}\) | \(115\) |
risch | \(2 a^{2} x A +a^{2} C x -\frac {i {\mathrm e}^{i \left (d x +c \right )} A \,a^{2}}{2 d}-\frac {7 i {\mathrm e}^{i \left (d x +c \right )} a^{2} C}{8 d}+\frac {i {\mathrm e}^{-i \left (d x +c \right )} A \,a^{2}}{2 d}+\frac {7 i {\mathrm e}^{-i \left (d x +c \right )} a^{2} C}{8 d}+\frac {A \,a^{2} \ln \left ({\mathrm e}^{i \left (d x +c \right )}+i\right )}{d}-\frac {A \,a^{2} \ln \left ({\mathrm e}^{i \left (d x +c \right )}-i\right )}{d}+\frac {\sin \left (3 d x +3 c \right ) a^{2} C}{12 d}+\frac {\sin \left (2 d x +2 c \right ) a^{2} C}{2 d}\) | \(170\) |
norman | \(\frac {\left (2 A \,a^{2}+a^{2} C \right ) x +\left (2 A \,a^{2}+a^{2} C \right ) x \left (\tan ^{8}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\left (8 A \,a^{2}+4 a^{2} C \right ) x \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\left (8 A \,a^{2}+4 a^{2} C \right ) x \left (\tan ^{6}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\left (12 A \,a^{2}+6 a^{2} C \right ) x \left (\tan ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )+\frac {2 a^{2} \left (A +C \right ) \left (\tan ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}+\frac {2 a^{2} \left (A +3 C \right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{d}+\frac {2 a^{2} \left (9 A +11 C \right ) \left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{3 d}+\frac {2 a^{2} \left (9 A +17 C \right ) \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{3 d}}{\left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )^{4}}+\frac {A \,a^{2} \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}{d}-\frac {A \,a^{2} \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}{d}\) | \(273\) |
[In]
[Out]
none
Time = 0.30 (sec) , antiderivative size = 95, normalized size of antiderivative = 0.99 \[ \int (a+a \cos (c+d x))^2 \left (A+C \cos ^2(c+d x)\right ) \sec (c+d x) \, dx=\frac {6 \, {\left (2 \, A + C\right )} a^{2} d x + 3 \, A a^{2} \log \left (\sin \left (d x + c\right ) + 1\right ) - 3 \, A a^{2} \log \left (-\sin \left (d x + c\right ) + 1\right ) + 2 \, {\left (C a^{2} \cos \left (d x + c\right )^{2} + 3 \, C a^{2} \cos \left (d x + c\right ) + {\left (3 \, A + 5 \, C\right )} a^{2}\right )} \sin \left (d x + c\right )}{6 \, d} \]
[In]
[Out]
\[ \int (a+a \cos (c+d x))^2 \left (A+C \cos ^2(c+d x)\right ) \sec (c+d x) \, dx=a^{2} \left (\int A \sec {\left (c + d x \right )}\, dx + \int 2 A \cos {\left (c + d x \right )} \sec {\left (c + d x \right )}\, dx + \int A \cos ^{2}{\left (c + d x \right )} \sec {\left (c + d x \right )}\, dx + \int C \cos ^{2}{\left (c + d x \right )} \sec {\left (c + d x \right )}\, dx + \int 2 C \cos ^{3}{\left (c + d x \right )} \sec {\left (c + d x \right )}\, dx + \int C \cos ^{4}{\left (c + d x \right )} \sec {\left (c + d x \right )}\, dx\right ) \]
[In]
[Out]
none
Time = 0.23 (sec) , antiderivative size = 107, normalized size of antiderivative = 1.11 \[ \int (a+a \cos (c+d x))^2 \left (A+C \cos ^2(c+d x)\right ) \sec (c+d x) \, dx=\frac {12 \, {\left (d x + c\right )} A a^{2} - 2 \, {\left (\sin \left (d x + c\right )^{3} - 3 \, \sin \left (d x + c\right )\right )} C a^{2} + 3 \, {\left (2 \, d x + 2 \, c + \sin \left (2 \, d x + 2 \, c\right )\right )} C a^{2} + 6 \, A a^{2} \log \left (\sec \left (d x + c\right ) + \tan \left (d x + c\right )\right ) + 6 \, A a^{2} \sin \left (d x + c\right ) + 6 \, C a^{2} \sin \left (d x + c\right )}{6 \, d} \]
[In]
[Out]
none
Time = 0.29 (sec) , antiderivative size = 179, normalized size of antiderivative = 1.86 \[ \int (a+a \cos (c+d x))^2 \left (A+C \cos ^2(c+d x)\right ) \sec (c+d x) \, dx=\frac {3 \, A a^{2} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 1 \right |}\right ) - 3 \, A a^{2} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 1 \right |}\right ) + 3 \, {\left (2 \, A a^{2} + C a^{2}\right )} {\left (d x + c\right )} + \frac {2 \, {\left (3 \, A a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 3 \, C a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 6 \, A a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 8 \, C a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 3 \, A a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 9 \, C a^{2} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 1\right )}^{3}}}{3 \, d} \]
[In]
[Out]
Time = 1.22 (sec) , antiderivative size = 159, normalized size of antiderivative = 1.66 \[ \int (a+a \cos (c+d x))^2 \left (A+C \cos ^2(c+d x)\right ) \sec (c+d x) \, dx=\frac {A\,a^2\,\sin \left (c+d\,x\right )}{d}+\frac {7\,C\,a^2\,\sin \left (c+d\,x\right )}{4\,d}+\frac {4\,A\,a^2\,\mathrm {atan}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )}{d}+\frac {2\,A\,a^2\,\mathrm {atanh}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )}{d}+\frac {2\,C\,a^2\,\mathrm {atan}\left (\frac {\sin \left (\frac {c}{2}+\frac {d\,x}{2}\right )}{\cos \left (\frac {c}{2}+\frac {d\,x}{2}\right )}\right )}{d}+\frac {C\,a^2\,\sin \left (2\,c+2\,d\,x\right )}{2\,d}+\frac {C\,a^2\,\sin \left (3\,c+3\,d\,x\right )}{12\,d} \]
[In]
[Out]